import { Select, SelectProps } from 'antd';
import '../styles/index.css';
import { cn } from '@/utils/cn-merge';

interface Props extends SelectProps {}

export const Tags = ({
  options,
  value,
  maxTagCount = 'responsive',
  className,
  tagRender,
  ...props
}: Props) => {
  return (
    <Select
      className={cn('rg-tags-select pointer-events-none', className)}
      mode="multiple"
      maxTagCount={maxTagCount}
      options={options}
      value={value}
      style={{ width: '100%' }}
      open={false}
      tagRender={tagRender}
      {...props}
    />
  );
};
